package com.taotao.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import com.taotao.common.pojo.TaotaoResult;
import com.taotao.search.webservice.SolrWebService;
import com.taotao.search.webservice.SolrWebService_Service;

@Controller
public class SolrController {
	@RequestMapping(value="/solr/createIndex")
	@ResponseBody
	public TaotaoResult createIndex() {
		SolrWebService_Service factory = new SolrWebService_Service();
		SolrWebService solrWebService = factory.getSolrWebServiceImplPort();
		TaotaoResult result = solrWebService.createIndex();
		return result;
	}
}
